:root {
    --primary-color: #4361ee;
    --secondary-color: #3a0ca3;
    --accent-color: #4895ef;
    --text-color: #2b2d42;
    --light-gray: #f8f9fa;
    --medium-gray: #e9ecef;
    --dark-gray: #6c757d;
    --white: #ffffff;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f7fa;
    color: var(--text-color);
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

.profile-container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background-color: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
}

.avatar-container {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.avatar {
    font-size: 3.5rem;
    color: var(--primary-color);
}

.user-meta h1 {
    margin: 0;
    font-size: 1.8rem;
    color: var(--text-color);
}

.user-role {
    display: inline-block;
    margin-top: 0.5rem;
    padding: 0.3rem 0.8rem;
    background-color: var(--light-gray);
    color: var(--dark-gray);
    border-radius: 20px;
    font-size: 0.9rem;
}

.logout-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background-color: var(--light-gray);
    color: var(--dark-gray);
    text-decoration: none;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
}

.logout-btn:hover {
    background-color: #f1f1f1;
    color: var(--primary-color);
}

.profile-content {
    display: grid;
    gap: 1.5rem;
}

.info-card, .action-card {
    background-color: var(--white);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.info-card h2, .action-card h2 {
    margin-top: 0;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.info-item {
    margin-bottom: 1rem;
}

.info-label {
    font-weight: 600;
    color: var(--dark-gray);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-value {
    padding: 0.8rem;
    background-color: var(--light-gray);
    border-radius: 6px;
    word-break: break-word;
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.2rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    flex-grow: 1;
    text-align: center;
    justify-content: center;
}

.action-btn.primary {
    background-color: var(--primary-color);
    color: white;
}

.action-btn {
    background-color: var(--light-gray);
    color: var(--text-color);
}

.action-btn.secondary {
    background-color: transparent;
    border: 1px solid var(--medium-gray);
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.action-btn.primary:hover {
    background-color: var(--secondary-color);
}

@media (max-width: 600px) {
    .profile-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .avatar-container {
        width: 100%;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }
}

/* 链接按钮 */
.links {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 30px;
}

.link-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
    text-align: center;
    min-width: 150px;
}

.link-button:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.link-button.secondary {
    background-color: #f5f5f5;
    color: #333;
    border: 1px solid #ddd;
}

.link-button.secondary:hover {
    background-color: #e5e5e5;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .info-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .info-label {
        margin-bottom: 5px;
    }

    .links {
        flex-direction: column;
    }

    .link-button {
        width: 100%;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.user-info {
    animation: fadeIn 0.5s ease-out;
}
